<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>欢迎光临</title>
	<link rel="stylesheet" type="text/css" href="/stylesheets/base.css">
	<link rel="stylesheet" type="text/css" href="/stylesheets/home.css">
	<link rel="stylesheet" type="text/css" href="/stylesheets/index.css">
	<style type="text/css" media="screen">
	

</style>
</head>
<body>
	<div id="all">
		<div id="top">
			<div id="topa">
				<ul>		
					<% for(var i =0 ;i<data.length;i++){%>
					<%if(data[i].a_name!=null){%>
                    <li id="a">欢迎*<a href="/gerenxinxi"><%=data[i].a_name%></a></li>
                    <li id="closeLogin"><a href="javascript:loginClose('<%=data[i].a_name%>')">退出登录</a></li>
                    <%break;%>
					<%}else if(i>3&&data[i].a_name==null){%>
					<li id="a"><a href="/login">亲！请登录</a></li>
					 <%break;%>
					<%}%>
					<%}%>
				</ul>
			</div>
			<div id="topb">
				<ul>
					<li ><a href="/hregist">后台管理</a></li>
					<li id="b"><a href=""><img src="/images/sm_r7_c23.jpg">联系客服</a></li>
				</ul>
			</div>
		</div>
		<div id="logo">
			<div id="img3"><img src="/images/touz.png" style="height: 100px  "></div>
			<div id="img2"><img src="/images/tou.png" style="height: 100px  "></div>

			<div id="img"><img src="/images/logo1.png" alt=""></div>
			<div id="ming">JOINFIT</div>
		</div>
		<div id="head">
			<ul>
				<li><a href="/">首页</a></li>
				<li ><a href="javascript:shopp_car()">购物车</a></li>
				<li ><a href="javascript:dingdan()">查看订单</a></li>
				<li ><a href="/huiyuan">会员修改</a></li>
				<li ><a href="/zhuce">注册有礼</a></li>
				<li ><a href="/liaotian">聊天室</a></li>
			</ul>
		</div>
		
		
		<% for(var i in data){
if(data[i].e_shoppTu==null){continue;}
		%>
		
			<img id="xx" width="100" height="150" src="/images/<%=data[i].e_shoppTu%>">
  			<div id="xshopp"><%=data[i].e_shopp%></div>
  			<div id="xs">类型：<%=data[i].e_shoppLeixing%></div>
  	        <div id="xp">价格：<%=data[i].e_price%>￥</div>
  			<div id="gwct"><a href="javascript:addCar('<%=data[i].e_shoppTu%>',<%=data[i].e_price%>,'<%=data[i].e_shopp%>')" class="aui-content-price-addcar"><img src="/images/gwc.png" alt=""></a></div>


  			<div id="submit">
				<input type="text" name="message" class="text" placeholder="请输入需要发送的消息" id="message">
				<a href="javascript:addPingJia(<%=data[i].e_id%>)" id="fasong">发送</a>
				<span id="NumberInfo" style="color:#f90b5c"></span>
			</form>
		</div>		
  		
		<%} %>
  	
				
<div id="pingjia">
		<table>
			<% for(var i =0 ;i<data.length;i++){%>
				<%if(data[i].h_message==null){%>
				<%continue;%>
				<%}%>
				<%if(data[i].h_admin_name=='管理员'){%>
				<tr>
					<td style="color:red"><%=data[i].h_admin_name%>*回复:</td>
					<td style="color:red"><%=data[i].h_message%></td>
				</tr>
				<%}else{%>
				<tr>
					<td>会员*<%=data[i].h_user_name%>*宝贝评价:</td>
					<td><%=data[i].h_message%></td>
				</tr>
				<%} %>
				<%} %>
		</table>
</div>
						
								
							
							<div id="food" class="latyou-box">
								           <span><a href="http://www.alibabagroup.com/cn/global/home">阿里巴巴集团</a></span><b>|</b>
            <span><a href="//www.taobao.com">淘宝网</a></span><b>|</b>
            <span><a href="//www.tmall.com">天猫</a></span><b>|</b>
            <span><a href="//ju.taobao.com">聚划算</a></span><b>|</b>
            <span><a href="http://www.aliexpress.com">全球速卖通</a></span><b>|</b>
            <span><a href="http://www.alibaba.com/">阿里巴巴国际交易市场</a></span><b>|</b>
            <span><a href="http://www.1688.com">1688</a></span><b>|</b>
            <span><a href="http://www.alimama.com">阿里妈妈</a></span><b>|</b>
            <span><a href="http://www.fliggy.com/">飞猪</a></span><b>|</b>
            <span><a href="http://www.aliyun.com">阿里云计算</a></span><b>|</b>
            <span><a href="http://www.alios.cn/">AliOS</a></span><b>|</b>
            <span><a href="http://www.aliqin.cn/">阿里通信</a></span><b>|</b>
            <span><a href="http://www.etao.com/">一淘</a></span><b>|</b>
            <span><a href="http://www.net.cn">万网</a></span><b>|</b>
            <span><a href="http://www.autonavi.com/">高德</a></span><b>|</b>
            <span><a href="http://www.uc.cn/">UC</a></span><b>|</b>
            <span><a href="http://www.umeng.com/">友盟</a></span>
            <span><a href="http://www.xiami.com">虾米</a></span><b>|</b>
            <span><a href="https://www.damai.cn/">大麦网</a></span><b>|</b>
            <span><a href="http://www.dingtalk.com/?lwfrom=20150130160830727">钉钉</a></span><b>|</b>
            <span><a href="https://www.alipay.com">支付宝</a></span><b>|</b>
            <span><a href="http://www.youku.com/">优酷</a></span><b>|</b>
            <span><a href="http://www.tudou.com/">土豆</a></span><b>|</b>
            <span><a href="http://www.alihealth.cn/">阿里健康</a></span><b>|</b>
            <span><a href="http://www.alibabapictures.com/simp/0-home.html">阿里影业</a></span><b>|</b>
            <span><a href="http://www.alisports.com/cn/">阿里体育</a></span><b>|</b>
            <span><a href="https://www.mybank.cn/">网商银行</a></span>
        </p>
        <p><span><a href="//img.alicdn.com/tps/i2/TB1YFcPLpXXXXaiXFXXcaDpFFXX-803-473.png">网络文化经营许可证：浙网文[2013]0268-027号</a></span><b>|</b>
            <span><a href="http://zcainfo.miitbeian.gov.cn/state/outPortal/loginPortal.action">增值电信业务经营许可证：浙B2-20080224</a></span><b>|</b>
            <span class="n">信息网络传播视听节目许可证：1109364号</span><b>|</b>
            <span class="n">互联网违法和不良信息举报电话：0571-81683755 blxxjb@alibaba-inc.com</span>
        </p>
							</div>
						</div>
					</div>
					</body>
					<script>
					


	function addCar(shoppTu,price,shopp) {  //添加购物车先判断
		if (document.getElementById('closeLogin')!=null) {  //如果有退出登录的 表示用户已经登录
		var str=`/shopp_addcar_handler?shoppTu=${shoppTu}&price=${price}&shopp=${shopp}`;
		location.href=str;
		}
	}
    
    function shopp_car(){   //跳转购物车需先判断
    	if (document.getElementById('closeLogin')!=null) {  //如果有退出登录的 表示用户已经登录 
    		var str=`/shopp_car`;
    		location.href=str;
    	}
    }


     function dingdan(){   //跳订单界面需先判断
    	if (document.getElementById('closeLogin')!=null) {  //如果有退出登录的 表示用户已经登录 
    		var str=`/dingdan`;
    		location.href=str;
    	}
    }

    function loginClose(t){
    	var str=`/login_close_handler?name=${t}`;
    	location.href=str;
    }
    function addPingJia(shoppID){
      var input=document.getElementById("message");
      var str=`/pingjia/handler?id=${shoppID}&message=${input.value}`;
    if (input.value<=0) {
      document.getElementById("NumberInfo").innerHTML="提交消息错误";
    }else{
		location.href=str;
	}
    }
</script>
</html>